(function() {
    let autoResize = {};
    autoResize.install = (Vue, options = {}) => {
        Vue.directive('autoResize', {
            inserted(el, binding, node) {
                setTimeout(() => {
                    node.componentInstance.handleResize();
                }, 500);
            }
        });
    };

    if (typeof exports == 'object') {
        module.exports = autoResize
    } else if (typeof define == 'function' && define.amd) {
        define([], () => autoResize)
    } else if (window.Vue) {
        window.autoResize = autoResize;
        Vue.use(autoResize)
    }
}());